﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Novapangeia.Negocio;

namespace Novapangeia.Web.home
{
    public partial class MenuUserControl : System.Web.UI.UserControl
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (new GerenciadorUsuario().consultarUsuarioDaSessao() != null)
            {
                MultiView1.ActiveViewIndex = 0;
            }
            else
            {
                MultiView1.ActiveViewIndex = 1;
            }
        }

        protected void linkButtonLogoff_Click(object sender, EventArgs e)
        {
            Session.Clear();
            Response.Redirect("~/home/Default.aspx");
        }
    }
}